package com.example.demo.controller;

import lombok.extern.log4j.Log4j;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;

import javax.servlet.http.HttpServletRequest;

/**
 * @Author YanJiaJian
 * @Date 2018/1/4 10:24
 */
@Controller
@Log4j
public class indexController {



    @GetMapping("/hello")
    public String index(HttpServletRequest request){
        log.info(request.getMethod()+":"+request.getRemoteAddr());
        return "hello world!";
    }

    @GetMapping("/picIndex")
    public String picIndex(){
        return "pic";
    }
}
